package demo01;

//子类, 狗类
public class Dog extends Animal {
    //1. 构造方法
    public Dog() {
    }

    public Dog(String name, int age) {
        super(name, age);
    }

    //2. 重写父类的抽象方法.
    @Override
    public void eat() {
        System.out.println("狗吃肉");
    }
}
